from data import *
import numpy as np

#算出ETF基金与对应股票的价差
diff = np.abs(result - ETFarray)

#分析适合步长的股票斜率(用1挺好的）
diff1 = []
for i in range(1,len(result)):
    diff1.append((result[i]-result[(i-1)])/1)
diff1 = np.append(np.nan,diff1)

#算出ETF的涨跌幅斜率
diffETF = []
for i in range(1,len(ETFarray)):
    diffETF.append((ETFarray[i]-ETFarray[(i-1)])/1)
diffETF = np.append(np.nan,diffETF)
